<?php

namespace App\Http\Requests;

use Illuminate\Foundation\Http\FormRequest;


class BillboardRequest extends FormRequest
{
    /**
     * Determine if the user is authorized to make this request.
     *
     * @return bool
     */
    public function authorize()
    {
        return true;
    }

    /**
     * Get the validation rules that apply to the request.
     *
     * @return array
     */
    public function rules()
    {
        return [
            'title'      => 'required|max:50',
            'lnglat'     => 'bail|required',
            'address'      => 'bail|required|max:200',
           
        ];
    }

    /**
     * 错误信息
     * @return array
     */
    public function messages()
    {
        return [
            'title.required'         => '请输入名称',            
            'lnglat.required'       => '请选择坐标点',
            'address.required'  => '请输入区域',
                 
        ];
    }

    
}
